
var test = (
	function(){
	
	}
)();

var test2  = (function(){});

var plugs=(function(){
     function addPlugs(name,plug)
     {
             var __plugs=this.__plugs=this.__plugs || {};
          if(name && plug)
          {
               __plugs[name]={
                  installed:false,
                  instance:plug
                  };
          }
         
     }
     
     function installPlugs()
     {
          var plugs=this.__plugs=this.__plugs || {};
          for(var i in plugs)
          {
              var plug=plugs[i];
              if(!plug.installed)
              {
                  plug.instance.install(this);
                  plug.installed=true;
              }
          }
     }
     
     return {
        ini:function(X)
        {
             X=monitor.ini(X);
             if(X.live)
             {
                 var proto=X.prototype;
                 proto.addPlugs=addPlugs;
                 proto.installPlugs=installPlugs;
             }

             X.__plugs={};
             X.addPlugs=addPlugs;
             X.installPlugs=installPlugs;
                 

        }
     }
})();

